import request from '@/utils/request'

const api_name='/admin/vod/teacher';

export default {

  //条件分页查询
  pageList(current,limit,searchObj){
    return request({
      url: `${api_name}/findQueryPage/${current}/${limit}`,
      method: 'post',
      data: searchObj
    })
  },
  removeTeacherId(id){
    return request({
      url: `${api_name}/remove/${id}`,
      method: 'delete',
    })
  },
  saveTeacher(teacher){
    return request({
      url: `${api_name}/saveTeacher`,
      method: 'post',
      data: teacher
    })
  },
  getById(id) {
    return request({
      url: `${api_name}/getTeacherById/${id}`,
      method: `get`
    })
  },
  updateTeacher(teacher){
    return request({
      url: `${api_name}/updateTeacher`,
      method: `put`,
      data: teacher
    })
  },
  batchRemove(idList) {
    return request({
      url: `${api_name}/removeByIdList`,
      method: `delete`,
      data: idList
    })
  },
  //查询所有讲师
  list() {
    return request({
      url: `${api_name}/findAll`,
      method: `get`,
    })
  },



}
